<form name="fault" action="addapprove.php" method="post">
<table border="1" width="600" align="center" cellpadding="0"cellspacing="0">
	<tr>
		
		<td>เสนอขออนุัมัติ<br>
		<textarea name="appdetail" id="appdetail" rows="8" cols="40"></textarea><br>
		ค่าใช้จ่าย <input type="text" name="appcost" id="appcost" ></input> </br>
		ผู้อนุมัติ <select name="app_user" id="app_user">
		<?php
		include('../config.inc.php');
		$sql = "select * from users where flag = 3";
		$result = mysql_query($sql);
		$num = mysql_num_rows($result);
		echo "<option value='0'>เลือกผู้อนุมัติ</option>";
		while(@$arr=mysql_fetch_array($result)){
			echo "<option value=\"".$arr['username']."\">".$arr['username']."</option>";
		}
		?>
		</select>  
		<input type="button" value="เสนออนุมัติ" name="app_submit" onClick="javascript:doAppFault()">
		
		</td>
	</tr>
</table>
</form>